// 对类的约束

interface Animal {
  name: string;
  eat():void;
}

class Dog implements Animal {
  name: string;
  constructor(name:string) {
    this.name = name
  }
  eat(): void {
    console.log(this.name + '吃狗粮')
  }
}

let d = new Dog('大黄')

d.eat()

export default () =>{}